import request from '@/utils/request'

// 添加购物车
export function addItemsToCart(data){
  return request({
    url:'/wx/goodsCar/addItemsToCart',
    method:'post',
    data:data
  })
}

// 获取购物车列表
export function findGoodsCarList(data){
  return request({
    url:'/wx/goodsCar/findGoodsCarList',
    method:'post',
    data:data
  })
}

// 删除购物车商品
export function delGoodsCar(data){
  return request({
    url:'/wx/goodsCar/delGoodsCar',
    method:'post',
    data:data
  })
}
 

// 修改购物车数量
export function updateGoodsNum(data){
  return request({
    url:'/wx/goodsCar/updateGoodsNum',
    method:'post',
    data:data
  })
}

// 添加收藏取消收藏
export function addordeleteGood(data){
  return request({
    url:'/wx/collect/addordelete',
    method:'post',
    data:data
  })
}

// 收藏列表
export function collectlist(data){
  return request({
    url:'/wx/collect/list',
    method:'post',
    data:data
  })
}

// 提交订单
export function submitOrder(data){
  return request({
    url:'/wx/order/submit',
    method:'post',
    data:data
  })
}
// 查询优惠券
export function mylist(data){
  return request({
    url:'/wx/coupon/mylist',
    method:'post',
    data
  })
}

// 购物车查询可用优惠券
export function checkUseCoupon(data){
  return request({
    url:'/wx/goodsCar/carCoupon',
    method:'post',
    data:data
  })
}

